<div class="dataInnBottom">
    <div class="dataHeader">
        <h4>My Progress</h4>
    </div>
    <div class="clr"></div>
    <?php $this->addScriptPath('../application/views/scripts/'); ?>
    <?= $this->paginationControl($this->paginator, 'Sliding', 'paginator.phtml') ?>
    <div class="clr"></div>
    <table class="dataActions" width="100%" border="0" cellpadding="0" cellspacing="0" >
        <tr>
            <th>Switch</th>
            <th>Month</th>
            <th>Monthly Target</th>
            <th>Reached</th>
            <th>Left</th>
            <th>Current Earnings</th>
        </tr>
        <?php foreach ($this->paginator as $item) {
        ?>
            <tr>
                <td><?php echo $item['switchName'] ?></td>
                <td><?php echo $item['month'] . '-' . $item['year'] ?></td>
                <td><?php echo $item['monthlytarget'] ?></td>
                <td><?php echo $item['reached'] ?></td>
                <td><?php echo $item['remaining'] ?></td>
                <td><?php echo $this->getCurrentEarning($item['contract_price'], $item['reached'], $item['monthlytarget'], $item['monthly_max'], $item['commission_percent'], $item['commission_percent_max']) ?></td>
            </tr>
        <?php } ?>
    </table>
</div>